package c.a.a.b0.l;

import android.graphics.Canvas;
import android.graphics.Matrix;
import android.graphics.Paint;
import android.graphics.Paint.Style;
import android.graphics.Path;
import android.graphics.RectF;
import b.f.e;
import c.a.a.b0.d;
import c.a.a.b0.j.k;
import c.a.a.f;
import c.a.a.f0.c;
import c.a.a.l;
import c.a.a.q;
import c.a.a.z.c.n;
import c.a.a.z.c.p;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/* compiled from: TextLayer */
public class i extends b {
    public final Paint A = new a(this, 1);
    public final Paint B = new b(this, 1);
    public final Map<d, List<c.a.a.z.b.d>> C = new HashMap();
    public final e<String> D = new e(10);
    public final n E;
    public final l F;
    public final f G;
    public c.a.a.z.c.a<Integer, Integer> H;
    public c.a.a.z.c.a<Integer, Integer> I;
    public c.a.a.z.c.a<Integer, Integer> J;
    public c.a.a.z.c.a<Integer, Integer> K;
    public c.a.a.z.c.a<Float, Float> L;
    public c.a.a.z.c.a<Float, Float> M;
    public c.a.a.z.c.a<Float, Float> N;
    public c.a.a.z.c.a<Float, Float> O;
    public c.a.a.z.c.a<Float, Float> P;
    public final StringBuilder x = new StringBuilder(2);
    public final RectF y = new RectF();
    public final Matrix z = new Matrix();

    /* compiled from: TextLayer */
    public class a extends Paint {
        public a(i iVar, int i) {
            super(i);
            setStyle(Style.FILL);
        }
    }

    /* compiled from: TextLayer */
    public class b extends Paint {
        public b(i iVar, int i) {
            super(i);
            setStyle(Style.STROKE);
        }
    }

    public i(l lVar, e eVar) {
        c.a.a.b0.j.a aVar;
        c.a.a.z.c.a a;
        super(lVar, eVar);
        this.F = lVar;
        this.G = eVar.b;
        n nVar = new n(eVar.q.a);
        this.E = nVar;
        nVar.a.add(this);
        e(nVar);
        k kVar = eVar.r;
        if (kVar != null) {
            aVar = kVar.a;
            if (aVar != null) {
                a = aVar.a();
                this.H = a;
                a.a.add(this);
                e(this.H);
            }
        }
        if (kVar != null) {
            aVar = kVar.b;
            if (aVar != null) {
                a = aVar.a();
                this.J = a;
                a.a.add(this);
                e(this.J);
            }
        }
        if (kVar != null) {
            c.a.a.b0.j.b bVar = kVar.c;
            if (bVar != null) {
                a = bVar.a();
                this.L = a;
                a.a.add(this);
                e(this.L);
            }
        }
        if (kVar != null) {
            c.a.a.b0.j.b bVar2 = kVar.d;
            if (bVar2 != null) {
                c.a.a.z.c.a a2 = bVar2.a();
                this.N = a2;
                a2.a.add(this);
                e(this.N);
            }
        }
    }

    public void b(RectF rectF, Matrix matrix, boolean z) {
        super.b(rectF, matrix, z);
        rectF.set(0.0f, 0.0f, (float) this.G.j.width(), (float) this.G.j.height());
    }

    public <T> void i(T t, c<T> cVar) {
        this.v.c(t, cVar);
        c.a.a.z.c.a aVar;
        p pVar;
        if (t == q.a) {
            aVar = this.I;
            if (aVar != null) {
                this.u.remove(aVar);
            }
            if (cVar == null) {
                this.I = null;
                return;
            }
            pVar = new p(cVar, null);
            this.I = pVar;
            pVar.a.add(this);
            e(this.I);
        } else if (t == q.b) {
            aVar = this.K;
            if (aVar != null) {
                this.u.remove(aVar);
            }
            if (cVar == null) {
                this.K = null;
                return;
            }
            pVar = new p(cVar, null);
            this.K = pVar;
            pVar.a.add(this);
            e(this.K);
        } else if (t == q.o) {
            aVar = this.M;
            if (aVar != null) {
                this.u.remove(aVar);
            }
            if (cVar == null) {
                this.M = null;
                return;
            }
            pVar = new p(cVar, null);
            this.M = pVar;
            pVar.a.add(this);
            e(this.M);
        } else if (t == q.p) {
            aVar = this.O;
            if (aVar != null) {
                this.u.remove(aVar);
            }
            if (cVar == null) {
                this.O = null;
                return;
            }
            pVar = new p(cVar, null);
            this.O = pVar;
            pVar.a.add(this);
            e(this.O);
        } else if (t == q.B) {
            aVar = this.P;
            if (aVar != null) {
                this.u.remove(aVar);
            }
            if (cVar == null) {
                this.P = null;
                return;
            }
            pVar = new p(cVar, null);
            this.P = pVar;
            pVar.a.add(this);
            e(this.P);
        }
    }

    /* JADX WARNING: Removed duplicated region for block: B:127:0x03d0  */
    public void l(android.graphics.Canvas r20, android.graphics.Matrix r21, int r22) {
        /*
        r19 = this;
        r0 = r19;
        r1 = r20;
        r20.save();
        r2 = r0.F;
        r2 = r2.b;
        r2 = r2.g;
        r2 = r2.i();
        r3 = 1;
        if (r2 <= 0) goto L_0x0016;
    L_0x0014:
        r2 = 1;
        goto L_0x0017;
    L_0x0016:
        r2 = 0;
    L_0x0017:
        if (r2 != 0) goto L_0x001c;
    L_0x0019:
        r20.concat(r21);
    L_0x001c:
        r2 = r0.E;
        r2 = r2.e();
        r2 = (c.a.a.b0.b) r2;
        r4 = r0.G;
        r4 = r4.e;
        r5 = r2.b;
        r4 = r4.get(r5);
        r4 = (c.a.a.b0.c) r4;
        if (r4 != 0) goto L_0x0036;
    L_0x0032:
        r20.restore();
        return;
    L_0x0036:
        r5 = r0.I;
        if (r5 == 0) goto L_0x004a;
    L_0x003a:
        r6 = r0.A;
        r5 = r5.e();
        r5 = (java.lang.Integer) r5;
        r5 = r5.intValue();
        r6.setColor(r5);
        goto L_0x0065;
    L_0x004a:
        r5 = r0.H;
        if (r5 == 0) goto L_0x005e;
    L_0x004e:
        r6 = r0.A;
        r5 = r5.e();
        r5 = (java.lang.Integer) r5;
        r5 = r5.intValue();
        r6.setColor(r5);
        goto L_0x0065;
    L_0x005e:
        r5 = r0.A;
        r6 = r2.h;
        r5.setColor(r6);
    L_0x0065:
        r5 = r0.K;
        if (r5 == 0) goto L_0x0079;
    L_0x0069:
        r6 = r0.B;
        r5 = r5.e();
        r5 = (java.lang.Integer) r5;
        r5 = r5.intValue();
        r6.setColor(r5);
        goto L_0x0094;
    L_0x0079:
        r5 = r0.J;
        if (r5 == 0) goto L_0x008d;
    L_0x007d:
        r6 = r0.B;
        r5 = r5.e();
        r5 = (java.lang.Integer) r5;
        r5 = r5.intValue();
        r6.setColor(r5);
        goto L_0x0094;
    L_0x008d:
        r5 = r0.B;
        r6 = r2.i;
        r5.setColor(r6);
    L_0x0094:
        r5 = r0.v;
        r5 = r5.j;
        if (r5 != 0) goto L_0x009d;
    L_0x009a:
        r5 = 100;
        goto L_0x00a7;
    L_0x009d:
        r5 = r5.e();
        r5 = (java.lang.Integer) r5;
        r5 = r5.intValue();
    L_0x00a7:
        r5 = r5 * 255;
        r5 = r5 / 100;
        r6 = r0.A;
        r6.setAlpha(r5);
        r6 = r0.B;
        r6.setAlpha(r5);
        r5 = r0.M;
        if (r5 == 0) goto L_0x00c9;
    L_0x00b9:
        r6 = r0.B;
        r5 = r5.e();
        r5 = (java.lang.Float) r5;
        r5 = r5.floatValue();
        r6.setStrokeWidth(r5);
        goto L_0x00f0;
    L_0x00c9:
        r5 = r0.L;
        if (r5 == 0) goto L_0x00dd;
    L_0x00cd:
        r6 = r0.B;
        r5 = r5.e();
        r5 = (java.lang.Float) r5;
        r5 = r5.floatValue();
        r6.setStrokeWidth(r5);
        goto L_0x00f0;
    L_0x00dd:
        r5 = c.a.a.e0.g.d(r21);
        r6 = r0.B;
        r7 = r2.j;
        r8 = c.a.a.e0.g.c();
        r8 = r8 * r7;
        r8 = r8 * r5;
        r6.setStrokeWidth(r8);
    L_0x00f0:
        r5 = r0.F;
        r5 = r5.b;
        r5 = r5.g;
        r5 = r5.i();
        if (r5 <= 0) goto L_0x00fe;
    L_0x00fc:
        r5 = 1;
        goto L_0x00ff;
    L_0x00fe:
        r5 = 0;
    L_0x00ff:
        r6 = 1120403456; // 0x42c80000 float:100.0 double:5.53552857E-315;
        if (r5 == 0) goto L_0x02c1;
    L_0x0103:
        r3 = r0.P;
        if (r3 == 0) goto L_0x0112;
    L_0x0107:
        r3 = r3.e();
        r3 = (java.lang.Float) r3;
        r3 = r3.floatValue();
        goto L_0x0114;
    L_0x0112:
        r3 = r2.c;
    L_0x0114:
        r3 = r3 / r6;
        r5 = c.a.a.e0.g.d(r21);
        r6 = r2.a;
        r7 = r2.f;
        r8 = c.a.a.e0.g.c();
        r8 = r8 * r7;
        r6 = r0.v(r6);
        r7 = r6.size();
        r9 = 0;
    L_0x012c:
        if (r9 >= r7) goto L_0x04c6;
    L_0x012e:
        r10 = r6.get(r9);
        r10 = (java.lang.String) r10;
        r11 = 0;
        r12 = 0;
    L_0x0136:
        r13 = r10.length();
        if (r12 >= r13) goto L_0x017a;
    L_0x013c:
        r13 = r10.charAt(r12);
        r14 = r4.a;
        r15 = r4.c;
        r13 = c.a.a.b0.d.a(r13, r14, r15);
        r14 = r0.G;
        r14 = r14.g;
        r13 = r14.d(r13);
        r13 = (c.a.a.b0.d) r13;
        if (r13 != 0) goto L_0x015a;
    L_0x0154:
        r13 = r8;
        r16 = r9;
        r22 = r10;
        goto L_0x0172;
    L_0x015a:
        r14 = (double) r11;
        r22 = r10;
        r10 = r13.c;
        r13 = r8;
        r16 = r9;
        r8 = (double) r3;
        r10 = r10 * r8;
        r8 = c.a.a.e0.g.c();
        r8 = (double) r8;
        r10 = r10 * r8;
        r8 = (double) r5;
        r10 = r10 * r8;
        r10 = r10 + r14;
        r8 = (float) r10;
        r11 = r8;
    L_0x0172:
        r12 = r12 + 1;
        r10 = r22;
        r8 = r13;
        r9 = r16;
        goto L_0x0136;
    L_0x017a:
        r13 = r8;
        r16 = r9;
        r22 = r10;
        r20.save();
        r8 = r2.d;
        r0.s(r8, r1, r11);
        r8 = r7 + -1;
        r8 = (float) r8;
        r8 = r8 * r13;
        r9 = 1073741824; // 0x40000000 float:2.0 double:5.304989477E-315;
        r8 = r8 / r9;
        r9 = r16;
        r10 = (float) r9;
        r10 = r10 * r13;
        r10 = r10 - r8;
        r8 = 0;
        r1.translate(r8, r10);
        r8 = 0;
    L_0x019a:
        r10 = r22.length();
        if (r8 >= r10) goto L_0x02b3;
    L_0x01a0:
        r10 = r22;
        r11 = r10.charAt(r8);
        r12 = r4.a;
        r14 = r4.c;
        r11 = c.a.a.b0.d.a(r11, r12, r14);
        r12 = r0.G;
        r12 = r12.g;
        r11 = r12.d(r11);
        r11 = (c.a.a.b0.d) r11;
        if (r11 != 0) goto L_0x01c4;
    L_0x01ba:
        r14 = r21;
        r22 = r6;
        r17 = r7;
        r16 = r10;
        goto L_0x02a9;
    L_0x01c4:
        r12 = r0.C;
        r12 = r12.containsKey(r11);
        if (r12 == 0) goto L_0x01db;
    L_0x01cc:
        r12 = r0.C;
        r12 = r12.get(r11);
        r12 = (java.util.List) r12;
        r22 = r6;
        r17 = r7;
        r16 = r10;
        goto L_0x0218;
    L_0x01db:
        r12 = r11.a;
        r14 = r12.size();
        r15 = new java.util.ArrayList;
        r15.<init>(r14);
        r16 = 0;
        r22 = r6;
        r6 = 0;
    L_0x01eb:
        if (r6 >= r14) goto L_0x020e;
    L_0x01ed:
        r16 = r12.get(r6);
        r17 = r7;
        r7 = r16;
        r7 = (c.a.a.b0.k.n) r7;
        r16 = r10;
        r10 = new c.a.a.z.b.d;
        r18 = r12;
        r12 = r0.F;
        r10.m7891init(r12, r0, r7);
        r15.add(r10);
        r6 = r6 + 1;
        r10 = r16;
        r7 = r17;
        r12 = r18;
        goto L_0x01eb;
    L_0x020e:
        r17 = r7;
        r16 = r10;
        r6 = r0.C;
        r6.put(r11, r15);
        r12 = r15;
    L_0x0218:
        r6 = 0;
    L_0x0219:
        r7 = r12.size();
        if (r6 >= r7) goto L_0x026f;
    L_0x021f:
        r7 = r12.get(r6);
        r7 = (c.a.a.z.b.d) r7;
        r7 = r7.h();
        r10 = r0.y;
        r14 = 0;
        r7.computeBounds(r10, r14);
        r10 = r0.z;
        r14 = r21;
        r10.set(r14);
        r10 = r0.z;
        r15 = r2.g;
        r15 = -r15;
        r18 = c.a.a.e0.g.c();
        r15 = r15 * r18;
        r18 = r12;
        r12 = 0;
        r10.preTranslate(r12, r15);
        r10 = r0.z;
        r10.preScale(r3, r3);
        r10 = r0.z;
        r7.transform(r10);
        r10 = r2.k;
        if (r10 == 0) goto L_0x0260;
    L_0x0255:
        r10 = r0.A;
        r0.u(r7, r10, r1);
        r10 = r0.B;
        r0.u(r7, r10, r1);
        goto L_0x026a;
    L_0x0260:
        r10 = r0.B;
        r0.u(r7, r10, r1);
        r10 = r0.A;
        r0.u(r7, r10, r1);
    L_0x026a:
        r6 = r6 + 1;
        r12 = r18;
        goto L_0x0219;
    L_0x026f:
        r14 = r21;
        r6 = r11.c;
        r6 = (float) r6;
        r6 = r6 * r3;
        r7 = c.a.a.e0.g.c();
        r7 = r7 * r6;
        r7 = r7 * r5;
        r6 = r2.e;
        r6 = (float) r6;
        r10 = 1092616192; // 0x41200000 float:10.0 double:5.398241246E-315;
        r6 = r6 / r10;
        r10 = r0.O;
        if (r10 == 0) goto L_0x0293;
    L_0x0288:
        r10 = r10.e();
        r10 = (java.lang.Float) r10;
        r10 = r10.floatValue();
        goto L_0x02a1;
    L_0x0293:
        r10 = r0.N;
        if (r10 == 0) goto L_0x02a2;
    L_0x0297:
        r10 = r10.e();
        r10 = (java.lang.Float) r10;
        r10 = r10.floatValue();
    L_0x02a1:
        r6 = r6 + r10;
    L_0x02a2:
        r6 = r6 * r5;
        r6 = r6 + r7;
        r7 = 0;
        r1.translate(r6, r7);
    L_0x02a9:
        r8 = r8 + 1;
        r6 = r22;
        r22 = r16;
        r7 = r17;
        goto L_0x019a;
    L_0x02b3:
        r14 = r21;
        r22 = r6;
        r17 = r7;
        r20.restore();
        r9 = r9 + 1;
        r8 = r13;
        goto L_0x012c;
    L_0x02c1:
        r14 = r21;
        c.a.a.e0.g.d(r21);
        r5 = r0.F;
        r7 = r4.a;
        r4 = r4.c;
        r8 = r5.getCallback();
        r9 = 0;
        if (r8 != 0) goto L_0x02d5;
    L_0x02d3:
        r5 = r9;
        goto L_0x02e6;
    L_0x02d5:
        r8 = r5.m;
        if (r8 != 0) goto L_0x02e4;
    L_0x02d9:
        r8 = new c.a.a.a0.a;
        r10 = r5.getCallback();
        r8.m693init(r10);
        r5.m = r8;
    L_0x02e4:
        r5 = r5.m;
    L_0x02e6:
        if (r5 == 0) goto L_0x034e;
    L_0x02e8:
        r8 = r5.a;
        r8.a = r7;
        r8.b = r4;
        r9 = r5.b;
        r8 = r9.get(r8);
        r9 = r8;
        r9 = (android.graphics.Typeface) r9;
        if (r9 == 0) goto L_0x02fa;
    L_0x02f9:
        goto L_0x034e;
    L_0x02fa:
        r8 = r5.c;
        r8 = r8.get(r7);
        r8 = (android.graphics.Typeface) r8;
        if (r8 == 0) goto L_0x0305;
    L_0x0304:
        goto L_0x031f;
    L_0x0305:
        r8 = "fonts/";
        r8 = c.b.a.a.a.i(r8, r7);
        r9 = r5.e;
        r8.append(r9);
        r8 = r8.toString();
        r9 = r5.d;
        r8 = android.graphics.Typeface.createFromAsset(r9, r8);
        r9 = r5.c;
        r9.put(r7, r8);
    L_0x031f:
        r7 = "Italic";
        r7 = r4.contains(r7);
        r9 = "Bold";
        r4 = r4.contains(r9);
        if (r7 == 0) goto L_0x0331;
    L_0x032d:
        if (r4 == 0) goto L_0x0331;
    L_0x032f:
        r4 = 3;
        goto L_0x033a;
    L_0x0331:
        if (r7 == 0) goto L_0x0335;
    L_0x0333:
        r4 = 2;
        goto L_0x033a;
    L_0x0335:
        if (r4 == 0) goto L_0x0339;
    L_0x0337:
        r4 = 1;
        goto L_0x033a;
    L_0x0339:
        r4 = 0;
    L_0x033a:
        r7 = r8.getStyle();
        if (r7 != r4) goto L_0x0342;
    L_0x0340:
        r9 = r8;
        goto L_0x0347;
    L_0x0342:
        r4 = android.graphics.Typeface.create(r8, r4);
        r9 = r4;
    L_0x0347:
        r4 = r5.b;
        r5 = r5.a;
        r4.put(r5, r9);
    L_0x034e:
        if (r9 != 0) goto L_0x0352;
    L_0x0350:
        goto L_0x04c6;
    L_0x0352:
        r4 = r2.a;
        r5 = r0.F;
        java.util.Objects.requireNonNull(r5);
        r5 = r0.A;
        r5.setTypeface(r9);
        r5 = r0.P;
        if (r5 == 0) goto L_0x036d;
    L_0x0362:
        r5 = r5.e();
        r5 = (java.lang.Float) r5;
        r5 = r5.floatValue();
        goto L_0x036f;
    L_0x036d:
        r5 = r2.c;
    L_0x036f:
        r7 = r0.A;
        r8 = c.a.a.e0.g.c();
        r8 = r8 * r5;
        r7.setTextSize(r8);
        r7 = r0.B;
        r8 = r0.A;
        r8 = r8.getTypeface();
        r7.setTypeface(r8);
        r7 = r0.B;
        r8 = r0.A;
        r8 = r8.getTextSize();
        r7.setTextSize(r8);
        r7 = r2.f;
        r8 = c.a.a.e0.g.c();
        r8 = r8 * r7;
        r7 = r2.e;
        r7 = (float) r7;
        r9 = 1092616192; // 0x41200000 float:10.0 double:5.398241246E-315;
        r7 = r7 / r9;
        r9 = r0.O;
        if (r9 == 0) goto L_0x03ad;
    L_0x03a2:
        r9 = r9.e();
        r9 = (java.lang.Float) r9;
        r9 = r9.floatValue();
        goto L_0x03bb;
    L_0x03ad:
        r9 = r0.N;
        if (r9 == 0) goto L_0x03bc;
    L_0x03b1:
        r9 = r9.e();
        r9 = (java.lang.Float) r9;
        r9 = r9.floatValue();
    L_0x03bb:
        r7 = r7 + r9;
    L_0x03bc:
        r9 = c.a.a.e0.g.c();
        r9 = r9 * r7;
        r9 = r9 * r5;
        r9 = r9 / r6;
        r4 = r0.v(r4);
        r5 = r4.size();
        r6 = 0;
    L_0x03ce:
        if (r6 >= r5) goto L_0x04c6;
    L_0x03d0:
        r7 = r4.get(r6);
        r7 = (java.lang.String) r7;
        r10 = r0.B;
        r10 = r10.measureText(r7);
        r11 = r7.length();
        r11 = r11 - r3;
        r3 = (float) r11;
        r3 = r3 * r9;
        r3 = r3 + r10;
        r20.save();
        r10 = r2.d;
        r0.s(r10, r1, r3);
        r3 = r5 + -1;
        r3 = (float) r3;
        r3 = r3 * r8;
        r10 = 1073741824; // 0x40000000 float:2.0 double:5.304989477E-315;
        r3 = r3 / r10;
        r10 = (float) r6;
        r10 = r10 * r8;
        r10 = r10 - r3;
        r3 = 0;
        r1.translate(r3, r10);
        r3 = 0;
    L_0x03fe:
        r10 = r7.length();
        if (r3 >= r10) goto L_0x04be;
    L_0x0404:
        r10 = r7.codePointAt(r3);
        r11 = java.lang.Character.charCount(r10);
        r11 = r11 + r3;
    L_0x040d:
        r12 = r7.length();
        if (r11 >= r12) goto L_0x044e;
    L_0x0413:
        r12 = r7.codePointAt(r11);
        r13 = java.lang.Character.getType(r12);
        r14 = 16;
        if (r13 == r14) goto L_0x0441;
    L_0x041f:
        r13 = java.lang.Character.getType(r12);
        r14 = 27;
        if (r13 == r14) goto L_0x0441;
    L_0x0427:
        r13 = java.lang.Character.getType(r12);
        r14 = 6;
        if (r13 == r14) goto L_0x0441;
    L_0x042e:
        r13 = java.lang.Character.getType(r12);
        r14 = 28;
        if (r13 == r14) goto L_0x0441;
    L_0x0436:
        r13 = java.lang.Character.getType(r12);
        r14 = 19;
        if (r13 != r14) goto L_0x043f;
    L_0x043e:
        goto L_0x0441;
    L_0x043f:
        r13 = 0;
        goto L_0x0442;
    L_0x0441:
        r13 = 1;
    L_0x0442:
        if (r13 != 0) goto L_0x0445;
    L_0x0444:
        goto L_0x044e;
    L_0x0445:
        r13 = java.lang.Character.charCount(r12);
        r11 = r11 + r13;
        r10 = r10 * 31;
        r10 = r10 + r12;
        goto L_0x040d;
    L_0x044e:
        r12 = r0.D;
        r13 = (long) r10;
        r10 = r12.a;
        if (r10 == 0) goto L_0x0458;
    L_0x0455:
        r12.d();
    L_0x0458:
        r10 = r12.b;
        r12 = r12.d;
        r10 = b.f.d.b(r10, r12, r13);
        if (r10 < 0) goto L_0x0464;
    L_0x0462:
        r10 = 1;
        goto L_0x0465;
    L_0x0464:
        r10 = 0;
    L_0x0465:
        if (r10 == 0) goto L_0x0470;
    L_0x0467:
        r10 = r0.D;
        r10 = r10.e(r13);
        r10 = (java.lang.String) r10;
        goto L_0x0493;
    L_0x0470:
        r10 = r0.x;
        r12 = 0;
        r10.setLength(r12);
        r10 = r3;
    L_0x0477:
        if (r10 >= r11) goto L_0x0488;
    L_0x0479:
        r12 = r7.codePointAt(r10);
        r15 = r0.x;
        r15.appendCodePoint(r12);
        r12 = java.lang.Character.charCount(r12);
        r10 = r10 + r12;
        goto L_0x0477;
    L_0x0488:
        r10 = r0.x;
        r10 = r10.toString();
        r11 = r0.D;
        r11.h(r13, r10);
    L_0x0493:
        r11 = r10.length();
        r3 = r3 + r11;
        r11 = r2.k;
        if (r11 == 0) goto L_0x04a7;
    L_0x049c:
        r11 = r0.A;
        r0.t(r10, r11, r1);
        r11 = r0.B;
        r0.t(r10, r11, r1);
        goto L_0x04b1;
    L_0x04a7:
        r11 = r0.B;
        r0.t(r10, r11, r1);
        r11 = r0.A;
        r0.t(r10, r11, r1);
    L_0x04b1:
        r11 = r0.A;
        r10 = r11.measureText(r10);
        r10 = r10 + r9;
        r11 = 0;
        r1.translate(r10, r11);
        goto L_0x03fe;
    L_0x04be:
        r20.restore();
        r6 = r6 + 1;
        r3 = 1;
        goto L_0x03ce;
    L_0x04c6:
        r20.restore();
        return;
        */
        throw new UnsupportedOperationException("Method not decompiled: c.a.a.b0.l.i.l(android.graphics.Canvas, android.graphics.Matrix, int):void");
    }

    public final void s(c.a.a.b0.b.a aVar, Canvas canvas, float f) {
        int ordinal = aVar.ordinal();
        if (ordinal == 1) {
            canvas.translate(-f, 0.0f);
        } else if (ordinal == 2) {
            canvas.translate((-f) / 2.0f, 0.0f);
        }
    }

    public final void t(String str, Paint paint, Canvas canvas) {
        if (paint.getColor() != 0) {
            if (paint.getStyle() != Style.STROKE || paint.getStrokeWidth() != 0.0f) {
                canvas.drawText(str, 0, str.length(), 0.0f, 0.0f, paint);
            }
        }
    }

    public final void u(Path path, Paint paint, Canvas canvas) {
        if (paint.getColor() != 0) {
            if (paint.getStyle() != Style.STROKE || paint.getStrokeWidth() != 0.0f) {
                canvas.drawPath(path, paint);
            }
        }
    }

    public final List<String> v(String str) {
        String str2 = "\r";
        return Arrays.asList(str.replaceAll("\r\n", str2).replaceAll("\n", str2).split(str2));
    }
}
